package cloud.simple.service;

import java.util.List;



import org.springframework.cloud.netflix.feign.FeignClient;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;

import cloud.simple.conf.FeignConfiguration;
import cloud.simple.model.User;

//https://github.com/spring-cloud/spring-cloud-netflix/blob/master/spring-cloud-netflix-core/src/main/java/org/springframework/cloud/netflix/feign/FeignClient.java
//@FeignClient(name="cloud-simple-service")
@FeignClient(name="yy",url="http://127.0.0.1:8082/users",configuration = FeignConfiguration.class)
//@FeignClient(name="yy",url="http://127.0.0.1:8081",fallback = HystrixClientFallback.class)
public interface SimpleClient {
	//@RequestMapping(method = RequestMethod.GET, value = "/users/user")
	@RequestMapping(method = RequestMethod.GET, value = "/user")
	List<User> searchAll();
}
